<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        let obj = {
            name:'夏总',
            getName: function(...args) {
                console.log(this.name);
            }
        }
        let obj2 = {
            name:'李总',
        }
        obj.getName(); // 夏总
        obj.getName.call(obj2); //           call一个一个传递参数
        obj.getName.apply(obj2); // 李总     apply 以数组的形式传递参数

        let func = obj.getname
        //未来执行
        func.bind(obj2)()

    </script>
</body>
</html>